<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>Layui</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" th:href="@{/layui/css/layui.css}" media="all">
    <script th:src="@{/layui/layui.js}" charset="utf-8"></script>
    <!-- 注意：如果你直接复制所有代码到本地，上述 JS 路径需要改成你本地的 -->
</head>
<body>


<fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
    <legend>课程详细情况</legend>
</fieldset>

<div class="layui-form-item">
    <div class="layui-inline">
        <label class="layui-form-label">课程名字</label>
        <div class="layui-input-inline">
            <input type="text" name="course_name" th:value="${course.course_name}" lay-verify="required"
                   readonly="readonly" autocomplete="off" class="layui-input">
        </div>
    </div>
    <div class="layui-inline">
        <label class="layui-form-label">课程价格</label>
        <div class="layui-input-inline">
            <input type="text" name="course_price" th:value="${course.course_price}" lay-verify="required"
                   readonly="readonly" autocomplete="off" class="layui-input">
        </div>
    </div>
    <div class="layui-inline">
        <label class="layui-form-label">教学方式</label>
        <div class="layui-input-inline">
            <input type="text" name="teach_way" th:value="${course.teach_way}" lay-verify="required" readonly="readonly"
                   autocomplete="off" class="layui-input">
        </div>
    </div>
</div>
<div class="layui-form-item">
    <div class="layui-inline">
        <label class="layui-form-label">教学地点</label>
        <div class="layui-input-inline">
            <input type="text" name="location" th:value="${course.location}" readonly="readonly" autocomplete="off"
                   class="layui-input">
        </div>
    </div>
    <div class="layui-inline">
        <label class="layui-form-label">教学天数</label>
        <div class="layui-input-inline">
            <input type="text" name="day" th:value="${course.day}" readonly="readonly" autocomplete="off"
                   class="layui-input">
        </div>
    </div>
    <div class="layui-inline">
        <label class="layui-form-label">备注</label>
        <div class="layui-input-inline">
            <input type="text" name="remark" th:value="${course.remark}" readonly="readonly" autocomplete="off"
                   class="layui-input">
        </div>
    </div>
</div>

<!--<div class="layui-form-item">-->
<!--<button type="button" onclick="doSave();" class="layui-btn" lay-submit="" lay-filter="demo2">订单入库</button>-->
<!--</div>-->

</form>


<script>
    var $, layer;
    layui.use('form', function () {
        var laydate = layui.laydate;
        layer = layui.layer;
        $ = layui.jquery;//拿到jQuery对象
    })

//     function doSave() {
//         //发送post请求
// //         语法：$.post(url,data,callback,type);
// //         url(必须):发送请求的地址，String类型
// //         data(可选):发送给后台的数据，以key/value形式{a:value1,b:value2}，即json格式
// //         callback(可选):请求成功后的回调函数。因此，在后台的处理中，需要给JSONObject put一个是否成功的值
// //         type(可选):即第二个参数data的数据类型。如果有data传递给后台，则需要加上该类型
//         var requestData = $("#addForm").serialize();//拿到表单数据
//         $.ajax({
//             type: 'POST',
//             url: "/courseOrderBase/save",
//             data: requestData,
//             success: function (responseData) {
//                 console.log(responseData);
//                 layer.alert("入库成功", {
//                     yes: function () {
//                         //页面由谁弹出来的就由谁关掉，index
//                         parent.layer.closeAll();
//                     }
//                 })
//             },
//             error: function () {
//
//             },
//             dataType: "json"
//         })
//     }
</script>

</body>
</html>